package com.qdevelop.vo;

public class Menu implements java.io.Serializable{

	private static final long serialVersionUID = 4059181994297268080L;
	private long id;			
	private String menuName	;
	private String linkurl;	
	private String target;
	private String icon;
	private int pid;		
	private int oper;
	public long getId() {
		return id;
	}
	public void setId(long id) {
		this.id = id;
	}
	public String getMenuName() {
		return menuName;
	}
	public void setMenuName(String menuName) {
		this.menuName = menuName;
	}
	public String getLinkurl() {
		return linkurl;
	}
	public void setLinkurl(String linkurl) {
		this.linkurl = linkurl;
	}
	public String getTarget() {
		return target==null?"mainframe":target;
	}
	public void setTarget(String target) {
		this.target = target;
	}
	public int getPid() {
		return pid;
	}
	public void setPid(int pid) {
		this.pid = pid;
	}
	public int getOper() {
		return oper;
	}
	public void setOper(int oper) {
		this.oper = oper;
	}	
	public String toString(){
		return this.menuName;
	}

	public String getIcon() {
		return icon;
	}
	public void setIcon(String icon) {
		this.icon = icon;
	}
	public String toFunctionTitle(int i){
		if(this.pid == 1){
			return this.menuName;
		}
		return "<a href='javascript:history.go(-"+i+");' class='title' target='"+this.getTarget()+"'>"+this.menuName+"</a>";
	}

}
